!function() {
	
	// 获得基础JIPIN对象
	var JIPIN = window.__NS__JIPIN;
	if(!JIPIN) { return; }
	var $ = JIPIN.$;
	
	if(inValidPage()) {
		JIPIN.getSitePicDesc = function(targetPic) {
			return $.trim(targetPic.closest('.feed-ct').children('.rich-content').text()) || '';
		}
		
		JIPIN.getSourceURL = function(targetPic) {
			var url = document.location.href,
				timeNode = targetPic.closest('.feed-content-holder').find('a.link-to-post');
			if(timeNode.length) {
				url = timeNode.get(0).href;
			}
			return url;
		}
	}
	
	function inValidPage() {
		return document.location.href.indexOf('www.diandian.com/home') !== -1;
	}
	
}();
